package main

import (
	"encoding/json"
    "fmt"
)

func main() {

	type (
		info struct {
			Armid int `json:"armid"`
			Index int `json:"index"`
		}

		change struct {
			Changes []info `json:"changes"`
		}
	)

    var msg change

    str := `{"changes": [{"armid": 3, "index": 5}, {"armid": 3, "index": 6}]}`
    err := json.Unmarshal([]byte(str), &msg)
    if err != nil {
        fmt.Println("Can't decode json message", err)
    }
    fmt.Println(msg.Changes)
	for _, v := range msg.Changes {
		fmt.Println(v.Armid, v.Index)
	}
	fmt.Println(msg)
}
